<!--# layout("/common/layout.html",{"jsBase":"/js/admin/article/"}){ -->

<form class="layui-form layui-form-pane" id="updateForm">
    <div class="layui-row">
        <div class="layui-form-item">
            <label class="layui-form-label">标题（中文）</label>
            <div class="layui-input-block">
                <input type="text" name="title" autocomplete="off" placeholder="请输入标题" class="layui-input" value="${article.title! }">
            </div>
        </div>
    </div>
    <div class="layui-row">
        <div class="layui-form-item">
            <label class="layui-form-label">标题（英文）</label>
            <div class="layui-input-block">
                <input type="text" name="titleEn" autocomplete="off" placeholder="请输入英文标题" class="layui-input" value="${article.titleEn! }">
            </div>
        </div>
    </div>
    <div class="layui-row">
        <div class="layui-form-item">
            <label class="layui-form-label">标题（意文）</label>
            <div class="layui-input-block">
                <input type="text" name="titleIt" autocomplete="off" placeholder="请输入意文标题" class="layui-input" value="${article.titleIt! }">
            </div>
        </div>
    </div>
    <div class="layui-row">
        <div class="layui-form-item">
            <div class="layui-inline">
				<label class="layui-form-label">所在栏目</label>
				<layui:catalogInput style='layui-input-inline' name="catalogId" id="catalogId" value="${article.catalogId!parseLong(parameter.catalogId!0) }"></layui:catalogInput>
			</div>
        </div>
    </div>
    <!--# if (false) { //暂时不使用此方式存放标签-->
    <div class="layui-row">
        <div class="layui-col-xs12 layui-col-xs4 layui-col-sm6">
            <div class="layui-form-item">
                <label class="layui-form-label">标签</label>
                <layui:articleTagCheckbox style='layui-input-block' dictType="article_tag" article="${article!}" id="tags" name="tags" articleId="${article.id!}" />
            </div>
        </div>
    </div>
    <!--# } -->
    <div class="layui-row">
        <div class="layui-col-xs12 layui-col-xs4 layui-col-sm6">
            <div class="layui-form-item">
                <label class="layui-form-label">标签</label>
                <div class="layui-input-block">
                    <input type="checkbox" name="top" value="1" lay-skin="primary" title="置顶" ${article.top!false?'checked=""':''} ${has(id)?("id=" + id):''}} />
                    <!--#
                        var dicts = dict.dictDownQuery('article_tag');

                        for(dict in dicts){
                        var dictValue = "" + dict.name + "";
                     -->
                    <input type="checkbox" name="tagValues" value="${dict.value}" lay-skin="primary" title="${dict.name}" ${util.contains(article.tagValue!,dict.value)?'checked=""':''} ${has(id)?("id=" + id):''} />
                    <!--#}-->
                </div>
            </div>
        </div>
    </div>
    <!--# if (false) {  -->
    <div class="layui-row">
        <div class="layui-form-item">
           	<label class="layui-form-label">城市选择</label>
			<div class="layui-input-block">
				<layui:areaSelect style='' itemId="area"></layui:areaSelect>
			</div>
        </div>
    </div>
    <!--# }  -->
    <div class="layui-row">
        <div class="layui-form-item">
           	<label class="layui-form-label">关键字</label>
			<div class="layui-input-block">
				<input type="text" name="keywords" class="layui-input"  value="${article.keywords! }" />
			</div>
        </div>
    </div>
    <div class="layui-row">
        <div class="layui-form-item">
           	<label class="layui-form-label">描述（中文）</label>
			<div class="layui-input-block">
				<input type="text" name="description" class="layui-input"  value="${article.description! }" />
			</div>
        </div>
    </div>
    <div class="layui-row">
        <div class="layui-form-item">
           	<label class="layui-form-label">描述（英文）</label>
			<div class="layui-input-block">
				<input type="text" name="descriptionEn" class="layui-input"  value="${article.descriptionEn! }" />
			</div>
        </div>
    </div>
    <div class="layui-row">
        <div class="layui-form-item">
           	<label class="layui-form-label">描述（意文）</label>
			<div class="layui-input-block">
				<input type="text" name="descriptionIt" class="layui-input"  value="${article.descriptionIt! }" />
			</div>
        </div>
    </div>
    <div class="layui-row">
        <div class="layui-form-item">
           	<label class="layui-form-label">url</label>
			<div class="layui-input-block">
				<input type="text" name="url" class="layui-input" value="${article.url! }" >
			</div>
        </div>
    </div>
    <div class="layui-row">
        <div class="layui-form-item">
            <div class="layui-inline">
            	<label class="layui-form-label">顺序</label>
				<div class="layui-input-inline">
					<input type="text" name="seq" class="layui-input"  value="${article.seq! }"/>
				</div>
            </div>
            <div class="layui-inline">
                <label class="layui-form-label">显示时间</label>
                <div class="layui-input-inline">
                    <input type="text" id="showTime" name="showTime"  value='${article.showTime!,"yyyy-MM-dd"}'   class="layui-input input-date" />
                </div>
            </div>
        </div>
        <div class="layui-form-item">
            <layui:submitButtons class="updateButton" />
        </div>
    </div>
    <div class="layui-row margin-top">
        <layui:image name="imageId" batchFileUUID="${article.imageId!uuid()}" isNew="false" bizId="${article.id!}" bizType="CmsArticle"/>
    </div>

    <div class="layui-row margin-top">
        <layui:attachment name="attachmentId" batchFileUUID="${article.attachmentId!uuid()}" isNew="false" bizId="${article.id! }" bizType="CmsArticle"/>
    </div>
    <div class="layui-row margin-top">
    	<div class="layui-form-item">
			<label class="layui-form-label">内容（中文）</label>
			<div class="layui-clear">
				<textarea class="kindEditor" name="content" style="display:none">${article.content! }</textarea>
			</div>
		</div>
        <div class="layui-form-item">
            <layui:submitButtons class="updateButton" />
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">内容（英文）</label>
            <div class="layui-clear">
                <textarea class="kindEditor" name="contentEn" style="display:none">${article.contentEn! }</textarea>
            </div>
        </div>
        <div class="layui-form-item">
            <layui:submitButtons class="updateButton" />
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">内容（意文）</label>
            <div class="layui-clear">
                <textarea class="kindEditor" name="contentIt" style="display:none">${article.contentIt! }</textarea>
            </div>
        </div>
	</div>
	<!-- 业务对象须有hidden字段，保存delFlag和version字段-->
    <input type="hidden" name="id" value="${article.id!}" />
    <input type="hidden" name="delFlag" value="${article.delFlag!0}" />
    <input type="hidden" name="fromPage" value="1" />
    <layui:submitButtons class="updateButton" />
</form>
<!--#} -->
<script>
layui.use(['edit'], function(){
    var articleEdit = layui.edit;
    articleEdit.init();
});
</script>
